package com.lingxu.api.ztb.mapper;

import com.lingxu.api.ztb.model.ConstructionDrawingFinalReview;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.lingxu.api.ztb.model.vo.ConstructionDrawingFinalReviewVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;


import java.util.List;

/**
 * 施工图设计终审表 Mapper接口
 *
 * @author admin
 * @since 2025-08-11
 */
@Mapper
public interface ConstructionDrawingFinalReviewMapper extends BaseMapper<ConstructionDrawingFinalReview> {
    /**
     * 查询施工图设计终审表
     *
     * @return
     */
    List<ConstructionDrawingFinalReviewVO> selectConstructionDrawingFinalReviewList(@Param("query") ConstructionDrawingFinalReviewVO vo);

    IPage<ConstructionDrawingFinalReviewVO> pageList(@Param("page") Page<ConstructionDrawingFinalReviewVO> page, @Param("query") ConstructionDrawingFinalReviewVO vo);

    List<ConstructionDrawingFinalReviewVO> getDataForExport(@Param("query") ConstructionDrawingFinalReviewVO vo);

    void createTempTable(@Param("batchFlag")String batchFlag);
    void insertTempTable(@Param("list") List<ConstructionDrawingFinalReviewVO> dataList, @Param("batchFlag")String batchFlag);
    void insertTable(@Param("batchFlag")String batchFlag);
    void dropTempTable(@Param("batchFlag")String batchFlag);
    List<ConstructionDrawingFinalReviewVO> selectUnionList(
            @Param("query") ConstructionDrawingFinalReviewVO vo,
            @Param("offset") int offset,
            @Param("pageSize") int pageSize
    );


    int countUnionList(@Param("query") ConstructionDrawingFinalReviewVO vo);
}
